<?php

namespace App\Model;

use Hyperf\Di\Annotation\Inject;
use Util\Common;
use App\Services\AdapayService;
use App\Services\FileService;
/**
 * 对公账户模型-模型
 */
class Business extends Model
{
    #[inject]
    protected AdapayService $adapayService;

    #[inject]
    protected FileService $fileService;


    const NORMAL = 0;
    const CHECKING = 1;
    const SUCCESS = 2;
    const ERROR = 3;
//    use TimeZoneTrait;

    public bool $timestamps = true;

    protected ?string $table = 'business';

    protected array $guarded = [
   ];


    protected array $casts = [
        'created_at' => 'datetime:Y-m-d H:i:s',
        'updated_at' => 'datetime:Y-m-d H:i:s',
    ];

    public function distributor(){
        return $this->belongsTo(Distributors::class,'distributor_id','id');
    }

}
